package com.lingjtx.common.core.constant;

import com.lingjtx.common.core.util.PropertiesUtil;

public class Const {
    public static final String WEBURL = PropertiesUtil.getProperty("web.url", "");
    public static final String SERVER_URL = PropertiesUtil.getProperty("server.url", "http://localhost:9999");
    public static final String SERVER_NAME = PropertiesUtil.getProperty("web.name", "灵境同学");
    public static final String SERVER_ICON = PropertiesUtil.getProperty("server.icon", "");
    public static final String SERVER_LOGO = PropertiesUtil.getProperty("server.logo", "");

    public static final String RSA_PUB_KEY = PropertiesUtil.getProperty("rsaPub.key");
    public static final String RSA_PRI_KEY = PropertiesUtil.getProperty("rsaPri.key");

    public static final String API_RSA_PUB_KEY = PropertiesUtil.getProperty("api.rsaPub.key");
    public static final String API_RSA_PRI_KEY = PropertiesUtil.getProperty("api.rsaPri.key");

    public static final String MD5_SALT = PropertiesUtil.getProperty("password.salt");

    public static final String ALIYUN_ACCESSKEY = PropertiesUtil.getProperty("aliyun.accessKeyId");
    public static final String ALIYUN_ACCESS_SECRET = PropertiesUtil.getProperty("aliyun.accessKeySecret");
    public static final String ALIYUN_OSS_ENDPOINT = PropertiesUtil.getProperty("oss.endpoint");

    public static final String WEIXIN_APPSECRET = PropertiesUtil.getProperty("weixin.secret");
    public static final String WEIXIN_APPID = PropertiesUtil.getProperty("weixin.appid");

    public static final String EMAIL_HOST = PropertiesUtil.getProperty("email.host");
    public static final String EMAIL_PORT = PropertiesUtil.getProperty("email.port");
    public static final String EMAIL_ENABLE = PropertiesUtil.getProperty("email.enable");
    public static final String EMAIL_PASSWORD = PropertiesUtil.getProperty("email.password");
    public static final String EMAIL_SENDER = PropertiesUtil.getProperty("email.sender");

    public static final String TEST_MOBILE = PropertiesUtil.getProperty("sms.test_mobile");

    public static final String DEFAULT_AVATAR = "http://oss-dev.mzzndq.cn/app/avatar/20240312144234817.png";

    // 照片、视频处理
    public interface ImageProcess {
        String IMG_LIST = "?x-oss-process=image/quality,Q_70";

        String VIDEO_COVER = "?x-oss-process=video/snapshot,t_1000,m_fast";

        // 水印文字：仅作为展示，复印无效
        String WATERMARK = "?x-oss-process=image/watermark,text_5LuF5L2c5Li65bGV56S677yM5aSN5Y2w5peg5pWI,fill_1,size_20,color_999999,rotate_315";
    }

    public interface AuthTokenMap {
        String AUTHORIZATION = "Authorization";
        String USER_TYPE = "User-Type";
    }

    public interface UserType {

        // C 端用户
        String TOC = "toc";

        // B 端用户
        String TOB = "tob";

        // 系统管理员运营用户
        String SYSTEM = "sys";

        // 开发者账号
        String DEVELOPER = "dev";
    }

    public interface ColStatus {
        byte DELETE = 0; // 删除
        byte NORMAL = 1;  // 正常
    }

    // 认证状态：0-不通过；1-已认证；2-审核中
    public interface AuthenticationStatus {
        byte NOT_PASS = 0; // 未认证
        byte CERTIFIED = 1;  // 已认证
        byte PASSING = 2;
    }

    // 登录状态：0-退出；1-登录
    public interface LoginStatus {
        byte LOGIN = 1;
        byte LOGOUT = 0;
    }

    // 家庭权限：0-成员；1-管理员;2-家庭创建者(系统管理员)
    public interface AdminAccount {
        byte MEMBER = 0;
        byte ADMIN = 1;
        byte SYSTEM = 2;
    }

    // 登录身份类型：1-手机登录；2-微信登录；3-邮箱登录；4-用户名登录
    public interface IdentityType {
        byte MOBILE = 1;
        byte WEXIN = 2;
        byte EMAIL = 3;
        byte USERNAME = 4;
        byte FACE = 5;
    }

    public interface ExamineStatus {
        byte NO_PASS = 0; // 不通过
        byte PASS = 1; // 通过
        byte IN_REVIEW = 2;// 审核中
        byte NONE = 3; // 未提交资料
    }

    // 操作结果：1-操作成功；2-操作失败；3-操作异常；4-操作超时
    public interface ActionResult {
        byte SUCCESS = 1;
        byte FAIL = 2;
        byte EXCEPTION = 3;
        byte TIMEOUT = 4;
    }

    // 应用类型：1-Android；2-iOS；3-固件
    public interface VersionAppType {
        byte ANDROID = 1;
        byte IOS = 2;
        byte BIN = 3;
    }

    public interface JiGangCode {
        int SUCCESS = 8000;
        int FAIL = 8001;
    }

    // 扫码状态：0-未扫码；1-已扫码；2-确认登录；3-二维码无效
    public interface ScanStatus {
        int NOT_SCAN = 0;
        int SCANED = 1;
        int CONFIRM = 2;
        int EXPIRE = 3;
    }

    public interface LLMModel {
        String deepseek_v3 = "deepseek-chat";

        String deepseek_r1 = "deepseek-reasoner";
    }

    public interface LLMDeltaType {

        // 引用内容
        String REF = "ref";

        // 推理思考链
        String THINKING = "thinking";

        // 回答正文内容
        String TEXT = "text";

        // 对话结束
        String FINISHED = "finished";
    }

    // 消息类型（如单聊、群聊、客服坐席（群聊）、心跳）
    public interface IMMsgType {

        int MAGIC = 0x1FA07CEE; // IM 二进制协议头

        byte ERROR = 0x00; // 错误提示消息

        byte HEARTBEAT = 0x01; // 心跳
        byte PRI_CHAT = 0x02; // 私聊
        byte GROUP_CHAT = 0x03; // 群聊
        byte KEFU = 0x04; // 客服群聊
        byte SYSTEM_NOTICE = 0x05; // 系统通知
    }
}
